package com.bdqn.service.impl;

import com.bdqn.entity.AddressBook;
import com.bdqn.entity.User;
import com.bdqn.mapper.UserMapper;
import com.bdqn.service.UserService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * <p>
 * 用户信息 服务实现类
 * </p>
 *
 * @author hunter
 * @since 2022-06-11
 */
@Service
public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements UserService {
    @Autowired
    private UserMapper userMapper;
    /**
     * 通过手机号获取对应的user_id
     * @param phone
     * @return
     */
    @Override
    public User selectByPhone(String phone) {
        return userMapper.selectByPhone(phone);
    }
}
